<?xml version="1.0" encoding="UTF-8"?>

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:p="http://primefaces.org/ui"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:portlet="http://java.sun.com/portlet_2_0">

    <h:panelGroup rendered="#{not iFeedModelBean.getFilters().isEmpty()}">

        <h:panelGroup rendered="#{app.inEditMode}" styleClass="ifeed-step" layout="block">
            <span>Din träfflista</span>
        </h:panelGroup>

        <h:panelGroup rendered="#{!app.inEditMode}" layout="block">
            <h2>Resultat</h2>
            <h:selectBooleanCheckbox value="#{app.limitOnResultCount}" rendered="false" />
        </h:panelGroup>

        <div class="#{app.inEditMode ? 'ifeed-filter-box' : ''}">
            <div
                    class="ifeedDocList"
                    columnes="dc.title|Titel (autokomplettering)|left|,dc.date.issued|Publicerad|left|"
                    fontSize="auto"
                    defaultsortcolumn="dc.title"
                    defaultsortorder="asc"
                    showTableHeader="yes"
                    linkOriginalDoc="no"
                    maxHitLimit="#{app.limitOnResultCount ? '100' : '0'}"
                    hiderightcolumn="yes"
                    feedid='#{iFeedModelBean.toJson()}'>
            </div>
        </div>
    <div id="ifeed-data2" style="display:none;">#{app.webScriptJsonUrl}</div>
    <button id="rerun-ifeed-loading" style="display:none;">Should be hidden</button>
    </h:panelGroup>
</ui:composition>